package cn.ujn.edu.microservice01mq.enums;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.Getter;

/**
 * @Author: shzhu
 * @Date: 2024/11/8 09:53
 * @Description:
 */
@Getter
public enum UserStatus {
    NORMAL(0, "正常"),
    FROZEN(1, "删除");

    @EnumValue  // 数据库中增删改查的值
    private int code;
    @JsonValue // 返回值
    private String desc;

    UserStatus(int code, String desc) {
        this.code = code;
        this.desc = desc;
    }
}
